package com.fourth.entity;

/**
 * 错误码统一处理类，所有的错误码统一定义在这里
 * @author Administrator
 *
 */
public class CodeMsg {
    private int code;//错误码

    private String msg;//错误信息

    /**
     * 构造函数私有化即单例模式
     * @param code
     * @param msg
     */
    private CodeMsg(int code, String msg){
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }



    public void setCode(int code) {
        this.code = code;
    }



    public String getMsg() {
        return msg;
    }



    public void setMsg(String msg) {
        this.msg = msg;
    }
    public static CodeMsg SUCCESS = new CodeMsg(200, "success");
    public static CodeMsg VALIDATE_ENTITY_ERROR = new CodeMsg(-3, "");
}
